﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ConsoleApp6
{
    class Program
    {
        static void Main(string[] args)
        {
            //int[] arr = { 64, 12, 47, 338 };
            //int sum = 0;
            //int max = arr[0];
            //int min = arr[0];
            //double avg = arr[0];
            //RefOut c = new RefOut();//             第一种ref作法
            //c.Shu(arr, ref sum, ref max, ref min, ref avg);
            //Console.WriteLine("sum: {0} max: {1} min: {2} avg: {3}", sum, max, min, avg);
            //RefOut b = new RefOut();//             第二种out作法;
            //b.Shu2(arr, out sum, out max, out min, out avg);
            //Console.WriteLine("sum: {0} max: {1} min: {2} avg: {3}", sum, max, min, avg);

            //StringUtilArrayUtil.StringUtil();
            //StringUtilArrayUtil.ArrayUtil();
            //test();
        }
        //public static void test()
        //{
        //    JinTai2 t = new JinTai2();
        //    t.Name1 = "孙悟空";
        //    t.Name2 = "猪八戒";
        //    t.Name3 = "沙悟净";
        //    t.Name4 = "白龙马";
        //    t.Test();
        //}
        enum DngDan
        {
            新订单,
            已发货,
            已签收,
            已评价
        }
        public enum Fruit
        {
            香蕉 = 10, 苹果 = 20, 西瓜 = 50, 草莓 = 2, 葡萄 = 1, 哈密瓜 = 30, 奇异果 = 5
        }
        public enum rpg
        {
            战士, 法师, 精灵
        }
        static void jineng()
        {
            Console.WriteLine("请输入职业");
            string shui = Console.ReadLine();
            rpg fruit = (rpg)Enum.Parse(typeof(rpg), shui);
            switch (fruit)
            {
                case rpg.战士:
                    Console.WriteLine("战士的技能：碎石打击、烈焰锚钩、战斗咆哮");
                    break;
                case rpg.法师:
                    Console.WriteLine("法师的技能：巨浪冲击、元素突击、复仇杀戮");
                    break;
                case rpg.精灵:
                    Console.WriteLine("精灵的技能：减速陷阱、能量浪潮、旋风剑舞");
                    break;
                default:
                    break;
            }
        }
        static void shuiguo()
        {
            Console.WriteLine("请输入水果");
            string shui = Console.ReadLine();
            Fruit fruit = (Fruit)Enum.Parse(typeof(Fruit), shui);

            switch (fruit)
            {
                case Fruit.哈密瓜:
                    Console.WriteLine((int)Fruit.哈密瓜);
                    break;
                case Fruit.香蕉:
                    Console.WriteLine((int)Fruit.香蕉);
                    break;
                case Fruit.苹果:
                    Console.WriteLine((int)Fruit.苹果);
                    break;
                case Fruit.西瓜:
                    Console.WriteLine((int)Fruit.西瓜);
                    break;
                case Fruit.草莓:
                    Console.WriteLine((int)Fruit.草莓);
                    break;
                case Fruit.葡萄:
                    Console.WriteLine((int)Fruit.葡萄);
                    break;
                case Fruit.奇异果:
                    Console.WriteLine((int)Fruit.奇异果);
                    break;
            }
        }
    }
}
